<?php
if (!defined('BASEPATH')) exit('No direct script access allowed');

class Totals_m extends FOX_Model
{

	function __construct ()
	{
		parent::__construct();
	}	
	
	public function user_all_num()
	{
		$this->db->select('user_id');
		$this->db->where('user_id >',0);	
		$this->db->from('users');
		$total=$this->db->count_all_results();
		return $total;
	}
	public function user_all_num_today()
	{
		$this->db->select('user_id');
		$this->db->where('user_regtime BETWEEN "'.strtotime(date("Y-m-d 00:00:00",time())).'" AND "'.strtotime(date("Y-m-d 23:59:59",time())).'"');	
		$this->db->from('users');
		$total=$this->db->count_all_results();
		return $total;
	}
	
}
